$(function(){
    showCondition(true);
	
    paramTabPage[tabId]= $("#tabContent > .tab-pane.active").data();
    if(typeof(paramTabPage[tabId].previous)=="undefined")
	{
		$('#'+tabId+' #hosp-title').append(paramTabPage[tabId].title);
	}
	else
	{
		if(paramTabPage[tabId].previous=="depGroup")
		{
			$('#'+tabId+' #hosp-title').append("科室组指标");
		}
		else if(paramTabPage[tabId].previous=="dep")
		{
			$('#'+tabId+' #hosp-title').append("科室指标");
		}
		else if(paramTabPage[tabId].monitorType=="mdc")
		{
			$('#'+tabId+' #hosp-title').append("MDC指标");
		}
		else if(paramTabPage[tabId].monitorType=="adrg")
		{
			$('#'+tabId+' #hosp-title').append("ADRG指标");
		}
		else if(paramTabPage[tabId].monitorType=="drgs")
		{
			$('#'+tabId+' #hosp-title').append("DRG指标");
		}
	}
	
	
	getQuotas("ybbDisLineWard", loadData, "dislinewardallhosp-ul","ward");
	
	function loadData(totalQuota){
		// 全院指标 (1.Hosp 2.All)  参数 4.为jsp中的div的id 5.jsp中ul的id
		loadHospQuota(paramTabPage[tabId].monitorType,totalQuota,"dislinewardallhospQuotasId","dislinewardallhosp-ul","ybDisLineWardTotal");
		// 加载指标的div 参数 3.为jsp中的div的id 4.jsp中ul的id
		loadDRGsQuota(totalQuota,"ward","病区","dislinewardListQuotasId","dislinewardList-ul");
	    // 科室组指标的数据加载 
	    loadDRGsQuotaData(totalQuota,"ward",true,"ybDisLineWardDetail");
	}
});

